package cn.smvc.common.dao;

import java.util.List;
import java.util.Map;

public interface BaseDao {
	
	public int update(String sql, Object... params);
	
	public int[] batchUpdate(String sql, Object[]...params);
	
	public List<Map<String, Object>> find(String sql, Object... params);
	
	public <T> List<T> find(Class<T> entityClass, String sql, Object...params);
	
	public <T> T findFirst(Class<T> entityClass, String sql, Object[] params);
	
	public Map<String, Object> findFirst(String sql, Object...params);
	
	public Object findBy(String sql, String columnName, Object...params);
	
	public Object findBy(String sql, int columnIndex, Object...params);

}
